package com.example.guiguihomemedical.controller;

import com.example.guiguihomemedical.common.Result;
import com.example.guiguihomemedical.entity.dto.RecordList;
import com.example.guiguihomemedical.service.RecordListService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequestMapping("recordlist")
public class RecordListController {
    @Autowired
    private RecordListService recordListService;
    @GetMapping
    public Result getRecordList(){
        List<RecordList> recordList=recordListService.getRecordList();
        return Result.success(recordList);
    }
}
